package com.example.entity;

import cn.idev.excel.annotation.ExcelIgnore;
import cn.idev.excel.annotation.ExcelProperty;
import cn.idev.excel.annotation.write.style.*;
import com.baomidou.mybatisplus.annotation.TableField;
import lombok.Data;

import java.io.Serializable;

/**
 * 员工信息
 */
@ContentRowHeight(20)
@HeadRowHeight(20)
@ColumnWidth(20)
@Data
public class Staff extends Account implements Serializable {

    private static final long serialVersionUID = 1L;

    @ExcelProperty("编号")
    private Integer id;

    @ExcelProperty("用户名")
    private String username;

    @ExcelIgnore   // 敏感字段不导出
    private String password;

    @ExcelProperty("姓名")
    private String name;

    @ExcelProperty("手机")
    private String phone;

    @ExcelProperty("邮箱")
    private String email;

    @ExcelIgnore
    private String avatar;

    @ExcelProperty("角色")
    private String role;

    @ExcelIgnore
    private Integer departmentId;

    @ExcelProperty("工号")
    private String workCode;

    @TableField(exist = false)
    @ExcelIgnore
    private String departmentName;
}